<template>
    <fieldset>
        <legend>兄弟组件</legend>
        <h1>一个兄弟组件</h1>
        <button>点击传给parent组件</button>
    </fieldset>
</template>

<script>
    import aa from "./1"
    console.log(aa);
    export default{}
</script>

<script>
    //EventBUs 就两个api

    //emit 触发事件

    //on监听事件

    //off 卸载事件监听
    export default{
        methods: {
            handleClick(){
                //传递
                console.log(this.$bus);
                this.$bus.$emit("get","马尔扎哈")
            }
        }
    }
</script>